// 注册相关接口

// 发送验证码
export function sendRegisterCode(phone: string) {
  return uni.request({
    url: '/yuan-code/api/sms/sendCode',
    method: 'POST',
    data: { phone },
    header: {
      'Content-Type': 'application/json',
    }
  })
}

// 注册账号
export function register(data: {
  phone: string
  code: string 
  password: string
}) {
  return uni.request({
    url: '/yuan-code/api/login/register',
    method: 'POST',
    data,
    header: {
      'Content-Type': 'application/json',
    }
  })
}
